using System.Windows;
using System.Windows.Markup;
using Common;

namespace MainView.Windows
{
	public partial class CreateExperimentReportWindow : Window, IComponentConnector
	{
		public CreateExperimentReportWindow()
		{
			InitializeComponent();
		}

		public string GetBoxText()
		{
			return file_name.Text;
		}

		private void btnOK_Click(object sender, RoutedEventArgs e)
		{
			if (string.IsNullOrEmpty(file_name.Text))
			{
				MessageBox.Show(Utility.GetMessage("msg_filename_is_null"), Utility.GetMessage("Warning"), MessageBoxButton.OK);
				return;
			}
			base.DialogResult = true;
			Close();
		}

		private void btnCancel_Click(object sender, RoutedEventArgs e)
		{
			Close();
		}
	}
}
